// -----------------------------------------------
// Author:     code34 nicolas_boiteux@yahoo.fr - MH6 - rework
// Edited by:  Neumatic
// Warcontext: Create a positions circle of x points around position
// -----------------------------------------------

private ["_a","_b","_positions","_dir","_position","_radius","_degree","_numberofposition"];

_position         = _this select 0;
_radius           = _this select 1;
_degree           = _this select 2;
_dir              = _this select 3;
_numberofposition = _this select 4;

_positions = [];
_dir = _dir - 90;
_degree = _degree / _numberofposition; 

for "_i" from 1 to _numberofposition do {
	_a = (_position select 0) + ((sin _dir) * _radius);
	_b = (_position select 1) + ((cos _dir) * _radius);
	_positions = _positions + [[_a, _b, _position select 2]];
	_dir = _dir + _degree;
};

_positions;